package com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile;

import com.beerandjesus.sportofkings.handicapper.model.RaceType;
import com.beerandjesus.sportofkings.handicapper.model.TrackSurface;
import org.apache.commons.lang.builder.ToStringBuilder;

public class RaceImpl implements Race, Cloneable {
	
	private String track;
	private String date;
	private String raceNumber;
	private String distance;
	private TrackSurface surface;
	private RaceType type;
	private String ageSexRestrictions;
	private String raceClassification;
	private String stateBredFlag;
	private String purse;
	private String claimingPrice;
	private String trackRecord;
	private String breedType;
	private String allWeatherSurfaceFlag;
	private String brisPacePar2f;
	private String brisPacePar4f;
	private String brisPacePar6f;
	private String brisSpeedPar;
	private String brisLatePacePar;
	private String postTimes;
	private String lasixList;
	private String buteList;
	private String coupledList;
	private String mutuelList;
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getTrack()
	 */
	public String getTrack() {
		return track;
	}
	public void setTrack(String track) {
		this.track = track;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getDate()
	 */
	public String getDate() {
		return date;
	}
	public void setDate(String date) {
		this.date = date;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getRaceNumber()
	 */
	public String getRaceNumber() {
		return raceNumber;
	}
	public void setRaceNumber(String raceNumber) {
		this.raceNumber = raceNumber;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getDistance()
	 */
	public String getDistance() {
		return distance;
	}
	public void setDistanceYards(String distanceYards) {
		this.distance = distanceYards;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getSurface()
	 */
	public TrackSurface getSurface() {
		return surface;
	}
	public void setSurface(TrackSurface surface) {
		this.surface = surface;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getType()
	 */
	public RaceType getType() {
		return type;
	}
	public void setType(RaceType type) {
		this.type = type;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getAgeSexRestrictions()
	 */
	public String getAgeSexRestrictions() {
		return ageSexRestrictions;
	}
	public void setAgeSexRestrictions(String ageSexRestrictions) {
		this.ageSexRestrictions = ageSexRestrictions;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getRaceClassification()
	 */
	public String getRaceClassification() {
		return raceClassification;
	}
	public void setRaceClassification(String raceClassification) {
		this.raceClassification = raceClassification;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getStateBredFlag()
	 */
	public String getStateBredFlag() {
		return stateBredFlag;
	}
	public void setStateBredFlag(String stateBredFlag) {
		this.stateBredFlag = stateBredFlag;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getPurse()
	 */
	public String getPurse() {
		return purse;
	}
	public void setPurse(String purse) {
		this.purse = purse;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getClaimingPrice()
	 */
	public String getClaimingPrice() {
		return claimingPrice;
	}
	public void setClaimingPrice(String claimingPrice) {
		this.claimingPrice = claimingPrice;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getTrackRecord()
	 */
	public String getTrackRecord() {
		return trackRecord;
	}
	public void setTrackRecord(String trackRecord) {
		this.trackRecord = trackRecord;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getBreedType()
	 */
	public String getBreedType() {
		return breedType;
	}
	public void setBreedType(String breedType) {
		this.breedType = breedType;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getAllWeatherSurfaceFlag()
	 */
	public String getAllWeatherSurfaceFlag() {
		return allWeatherSurfaceFlag;
	}
	public void setAllWeatherSurfaceFlag(String allWeatherSurfaceFlag) {
		this.allWeatherSurfaceFlag = allWeatherSurfaceFlag;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getBrisPacePar2f()
	 */
	public String getBrisPacePar2f() {
		return brisPacePar2f;
	}
	public void setBrisPacePar2f(String brisPacePar2f) {
		this.brisPacePar2f = brisPacePar2f;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getBrisPacePar4f()
	 */
	public String getBrisPacePar4f() {
		return brisPacePar4f;
	}
	public void setBrisPacePar4f(String brisPacePar4f) {
		this.brisPacePar4f = brisPacePar4f;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getBrisPacePar6f()
	 */
	public String getBrisPacePar6f() {
		return brisPacePar6f;
	}
	public void setBrisPacePar6f(String brisPacePar6f) {
		this.brisPacePar6f = brisPacePar6f;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getBrisSpeedPar()
	 */
	public String getBrisSpeedPar() {
		return brisSpeedPar;
	}
	public void setBrisSpeedPar(String brisSpeedPar) {
		this.brisSpeedPar = brisSpeedPar;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getBrisLatePacePar()
	 */
	public String getBrisLatePacePar() {
		return brisLatePacePar;
	}
	public void setBrisLatePacePar(String brisLatePacePar) {
		this.brisLatePacePar = brisLatePacePar;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getPostTimes()
	 */
	public String getPostTimes() {
		return postTimes;
	}
	public void setPostTimes(String postTimes) {
		this.postTimes = postTimes;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getLasixList()
	 */
	public String getLasixList() {
		return lasixList;
	}
	public void setLasixList(String lasixList) {
		this.lasixList = lasixList;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getButeList()
	 */
	public String getButeList() {
		return buteList;
	}
	public void setButeList(String buteList) {
		this.buteList = buteList;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getCoupledList()
	 */
	public String getCoupledList() {
		return coupledList;
	}
	public void setCoupledList(String coupledList) {
		this.coupledList = coupledList;
	}
	/* (non-Javadoc)
	 * @see com.beerandjesus.sportofkings.handicapper.model.brisnet.singlefile.Race#getMutuelList()
	 */
	public String getMutuelList() {
		return mutuelList;
	}
	public void setMutuelList(String mutuelList) {
		this.mutuelList = mutuelList;
	}


    @Override
    public Race clone() {
        try {
            return (Race) super.clone();
        } catch (CloneNotSupportedException e) {
            throw new RuntimeException("Clone not supported", e);
        }
    }

    public String toString() {
        return ToStringBuilder.reflectionToString(this);
    }

    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        RaceImpl race = (RaceImpl) o;

        if (ageSexRestrictions != null ? !ageSexRestrictions.equals(race.ageSexRestrictions) : race.ageSexRestrictions != null)
            return false;
        if (allWeatherSurfaceFlag != null ? !allWeatherSurfaceFlag.equals(race.allWeatherSurfaceFlag) : race.allWeatherSurfaceFlag != null)
            return false;
        if (breedType != null ? !breedType.equals(race.breedType) : race.breedType != null) return false;
        if (brisLatePacePar != null ? !brisLatePacePar.equals(race.brisLatePacePar) : race.brisLatePacePar != null)
            return false;
        if (brisPacePar2f != null ? !brisPacePar2f.equals(race.brisPacePar2f) : race.brisPacePar2f != null)
            return false;
        if (brisPacePar4f != null ? !brisPacePar4f.equals(race.brisPacePar4f) : race.brisPacePar4f != null)
            return false;
        if (brisPacePar6f != null ? !brisPacePar6f.equals(race.brisPacePar6f) : race.brisPacePar6f != null)
            return false;
        if (brisSpeedPar != null ? !brisSpeedPar.equals(race.brisSpeedPar) : race.brisSpeedPar != null) return false;
        if (buteList != null ? !buteList.equals(race.buteList) : race.buteList != null) return false;
        if (claimingPrice != null ? !claimingPrice.equals(race.claimingPrice) : race.claimingPrice != null)
            return false;
        if (coupledList != null ? !coupledList.equals(race.coupledList) : race.coupledList != null) return false;
        if (date != null ? !date.equals(race.date) : race.date != null) return false;
        if (distance != null ? !distance.equals(race.distance) : race.distance != null) return false;
        if (lasixList != null ? !lasixList.equals(race.lasixList) : race.lasixList != null) return false;
        if (mutuelList != null ? !mutuelList.equals(race.mutuelList) : race.mutuelList != null) return false;
        if (postTimes != null ? !postTimes.equals(race.postTimes) : race.postTimes != null) return false;
        if (purse != null ? !purse.equals(race.purse) : race.purse != null) return false;
        if (raceClassification != null ? !raceClassification.equals(race.raceClassification) : race.raceClassification != null)
            return false;
        if (raceNumber != null ? !raceNumber.equals(race.raceNumber) : race.raceNumber != null) return false;
        if (stateBredFlag != null ? !stateBredFlag.equals(race.stateBredFlag) : race.stateBredFlag != null)
            return false;
        if (surface != race.surface) return false;
        if (track != null ? !track.equals(race.track) : race.track != null) return false;
        if (trackRecord != null ? !trackRecord.equals(race.trackRecord) : race.trackRecord != null) return false;
        if (type != race.type) return false;

        return true;
    }

    public int hashCode() {
        int result;
        result = (track != null ? track.hashCode() : 0);
        result = 31 * result + (date != null ? date.hashCode() : 0);
        result = 31 * result + (raceNumber != null ? raceNumber.hashCode() : 0);
        result = 31 * result + (distance != null ? distance.hashCode() : 0);
        result = 31 * result + (surface != null ? surface.hashCode() : 0);
        result = 31 * result + (type != null ? type.hashCode() : 0);
        result = 31 * result + (ageSexRestrictions != null ? ageSexRestrictions.hashCode() : 0);
        result = 31 * result + (raceClassification != null ? raceClassification.hashCode() : 0);
        result = 31 * result + (stateBredFlag != null ? stateBredFlag.hashCode() : 0);
        result = 31 * result + (purse != null ? purse.hashCode() : 0);
        result = 31 * result + (claimingPrice != null ? claimingPrice.hashCode() : 0);
        result = 31 * result + (trackRecord != null ? trackRecord.hashCode() : 0);
        result = 31 * result + (breedType != null ? breedType.hashCode() : 0);
        result = 31 * result + (allWeatherSurfaceFlag != null ? allWeatherSurfaceFlag.hashCode() : 0);
        result = 31 * result + (brisPacePar2f != null ? brisPacePar2f.hashCode() : 0);
        result = 31 * result + (brisPacePar4f != null ? brisPacePar4f.hashCode() : 0);
        result = 31 * result + (brisPacePar6f != null ? brisPacePar6f.hashCode() : 0);
        result = 31 * result + (brisSpeedPar != null ? brisSpeedPar.hashCode() : 0);
        result = 31 * result + (brisLatePacePar != null ? brisLatePacePar.hashCode() : 0);
        result = 31 * result + (postTimes != null ? postTimes.hashCode() : 0);
        result = 31 * result + (lasixList != null ? lasixList.hashCode() : 0);
        result = 31 * result + (buteList != null ? buteList.hashCode() : 0);
        result = 31 * result + (coupledList != null ? coupledList.hashCode() : 0);
        result = 31 * result + (mutuelList != null ? mutuelList.hashCode() : 0);
        return result;
    }

}
